package com.iscale.system.validator.BannerControllerForm;


import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

/**
 * Created by ouyangan on 2017/2/23.
 */
@ApiModel(value = "ceshi")
public class BannerInsertForm {
    // status :数据状态,1:正常,2:删除
    @Min(value = 1, message = "请选择状态:启用/禁用")
    @Max(value = 3, message = "请选择状态:启用/禁用")
    @ApiModelProperty(value = "状态", required = true)
    private Integer status;

    // title :标题
    @NotBlank(message = "请输入标题")
    @ApiModelProperty
    private String title;

    // file_id :图片文件id
    @NotNull(message = "请上传文件")
    @ApiModelProperty
    private Long fileId;

    // redirect_url :条状url
    @NotBlank(message = "请输入跳转链接")
    @ApiModelProperty
    private String redirectUrl;

    // remark :备注
    @ApiModelProperty
    private String remark;

    // rank :排序
    @Min(value = 1, message = "请输入序号")
    @ApiModelProperty
    private Long rank;

    @Override
    public String toString() {
        return "BannerInsertForm{" +
                "status=" + status +
                ", title='" + title + '\'' +
                ", fileId=" + fileId +
                ", redirectUrl='" + redirectUrl + '\'' +
                ", remark='" + remark + '\'' +
                ", rank=" + rank +
                '}';
    }

    public Integer getStatus() {
        return status;
    }

    public String getTitle() {
        return title;
    }

    public Long getFileId() {
        return fileId;
    }

    public String getRedirectUrl() {
        return redirectUrl;
    }

    public String getRemark() {
        return remark;
    }

    public Long getRank() {
        return rank;
    }
}
